package com.itheima.sh.m_block_13;

public class Student {
    static int number=80;
    static String schoolName;
    //静态代码块
    static {
        System.out.println("静态代码块被执行了~~~");
        schoolName="黑马程序员";
    }
    int age;
    //实例代码块
    {
        System.out.println("实例代码块被执行了~~~");
       age=18;
    }

    //无参构造器
    public  Student(){
        System.out.println("无参构造器执行了~~~~");
    }
    //有参构造器
    public  Student(String name){
        System.out.println("有参构造器执行了~~~~");
    }
}
